package jackson.src.day01;

import java.util.HashMap;
import java.util.Map;

/*
 * Author: JacksonCoder
 * FileName: basic
 * Version: 1.0.0
 */
public class basic {

    public static void useMap(){
        Map<Integer,Integer> map = new HashMap<>();
        int[] nums = {3,2,0,-1};

        for(int i = 0; i < nums.length; i++){
            if(map.containsKey(nums[i])){
                map.put(nums[i], map.get(nums[i]) + 1);
            }
            map.put(nums[i],  1);
        }
        System.out.println("map = " + map);

    }

    public static void main(String[] args) {
        System.out.println("this is function entry");
        useMap();

        int[][] lists = {{1, 3, 5}, {1, 3, 4}, {2, 6}};
        // 打印   lists
        for (int i = 0; i < lists.length; i++) {
            for (int j = 0; j < lists[i].length; j++) {
                System.out.print(lists[i][j] + " ");
            }
        }
    }
}
